package com.hqhsc.module.manage.channel.domain;

import org.springframework.jdbc.core.RowMapper;

import java.sql.ResultSet;
import java.sql.SQLException;

public class ChannelRowMapper implements RowMapper<Channel>{
	public Channel mapRow(ResultSet rs, int arg1) throws SQLException {
        Channel channel=new Channel();

        channel.setId(rs.getInt("id"));
        channel.setName(rs.getString("name"));
        channel.setWebsite_url(rs.getString("website_url"));
        channel.setChannel_type(rs.getInt("channel_type"));
        channel.setActivity_num(rs.getInt("activity_num"));
        channel.setSpread_position(rs.getString("spread_position"));
        channel.setSpread_cycle(rs.getString("spread_cycle"));
        channel.setSpread_content(rs.getString("spread_content"));
        channel.setSpread_cost(rs.getString("spread_cost"));
        channel.setPv(rs.getInt("pv"));
        channel.setUv(rs.getInt("uv"));
        channel.setPoint_count(rs.getInt("point_count"));
        channel.setSignup_count(rs.getInt("signup_count"));
        channel.setOrg_id(rs.getInt("org_id"));
        channel.setCreate_by(rs.getInt("create_by"));

		return channel;
	}
}
